package com.jack.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import com.jack.entity.User;
import com.jack.service.UserFeignClient;

@RestController
public class UserMovieController {

	@Autowired
	private UserFeignClient userFeignClient;
	
	@GetMapping("/user/{id}")
	public User findOne(@PathVariable Long id){
		User user =userFeignClient.findById(id);
		return user;
	}
	
	
}
